package svc

import (
	"github.com/zeromicro/go-zero/zrpc"
	"store-kit/api/internal/config"
	"store-kit/storerpc/storerpcclient"
)

type ServiceContext struct {
	Config   config.Config
	StoreRpc storerpcclient.Storerpc
}

func NewServiceContext(c config.Config) *ServiceContext {
	return &ServiceContext{
		Config:   c,
		StoreRpc: storerpcclient.NewStorerpc(zrpc.MustNewClient(c.StoreRpc)),
	}
}
